Optimal. Leaf size=78 \[ -\frac {(a+b)^3 \text {ArcTan}\left (\frac {\sqrt {b} \cosh (x)}{\sqrt {a}}\right )}{\sqrt {a} b^{7/2}}+\frac {\left (a^2+3 a b+3 b^2\right ) \cosh (x)}{b^3}-\frac {(a+3 b) \cosh ^3(x)}{3 b^2}+\frac {\cosh ^5(x)}{5 b} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.08, antiderivative size = 78, normalized size of antiderivative = 1.00, number of steps
used = 4, number of rules used = 3, integrand size = 15, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.200, Rules used = {3269, 398, 211}
\begin {gather*} \frac {\left (a^2+3 a b+3 b^2\right ) \cosh (x)}{b^3}-\frac {(a+b)^3 \text {ArcTan}\left (\frac {\sqrt {b} \cosh (x)}{\sqrt {a}}\right )}{\sqrt {a} b^{7/2}}-\frac {(a+3 b) \cosh ^3(x)}{3 b^2}+\frac {\cosh ^5(x)}{5 b} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 211
Rule 398
Rule 3269
Rubi steps
\begin {align*} \int \frac {\sinh ^7(x)}{a+b \cosh ^2(x)} \, dx &=-\text {Subst}\left (\int \frac {\left (1-x^2\right )^3}{a+b x^2} \, dx,x,\cosh (x)\right )\\ &=-\text {Subst}\left (\int \left (-\frac {a^2+3 a b+3 b^2}{b^3}+\frac {(a+3 b) x^2}{b^2}-\frac {x^4}{b}+\frac {a^3+3 a^2 b+3 a b^2+b^3}{b^3 \left (a+b x^2\right )}\right ) \, dx,x,\cosh (x)\right )\\ &=\frac {\left (a^2+3 a b+3 b^2\right ) \cosh (x)}{b^3}-\frac {(a+3 b) \cosh ^3(x)}{3 b^2}+\frac {\cosh ^5(x)}{5 b}-\frac {(a+b)^3 \text {Subst}\left (\int \frac {1}{a+b x^2} \, dx,x,\cosh (x)\right )}{b^3}\\ &=-\frac {(a+b)^3 \tan ^{-1}\left (\frac {\sqrt {b} \cosh (x)}{\sqrt {a}}\right )}{\sqrt {a} b^{7/2}}+\frac {\left (a^2+3 a b+3 b^2\right ) \cosh (x)}{b^3}-\frac {(a+3 b) \cosh ^3(x)}{3 b^2}+\frac {\cosh ^5(x)}{5 b}\\ \end {align*}
________________________________________________________________________________________
Mathematica [C] Result contains complex when optimal does not.
time = 0.17, size = 148, normalized size = 1.90 \begin {gather*} -\frac {(a+b)^3 \text {ArcTan}\left (\frac {\sqrt {b}-i \sqrt {a+b} \tanh \left (\frac {x}{2}\right )}{\sqrt {a}}\right )}{\sqrt {a} b^{7/2}}-\frac {(a+b)^3 \text {ArcTan}\left (\frac {\sqrt {b}+i \sqrt {a+b} \tanh \left (\frac {x}{2}\right )}{\sqrt {a}}\right )}{\sqrt {a} b^{7/2}}+\frac {\left (8 a^2+22 a b+19 b^2\right ) \cosh (x)}{8 b^3}-\frac {(4 a+9 b) \cosh (3 x)}{48 b^2}+\frac {\cosh (5 x)}{80 b} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [B] Leaf count of result is larger than twice the leaf count of optimal. \(244\) vs.
\(2(66)=132\).
time = 0.66, size = 245, normalized size = 3.14
method | result | size |
default | \(-\frac {1}{5 b \left (\tanh \left (\frac {x}{2}\right )-1\right )^{5}}-\frac {1}{2 b \left (\tanh \left (\frac {x}{2}\right )-1\right )^{4}}-\frac {-4 a -3 b}{12 b^{2} \left (\tanh \left (\frac {x}{2}\right )-1\right )^{3}}-\frac {-7 b -4 a}{8 b^{2} \left (\tanh \left (\frac {x}{2}\right )-1\right )^{2}}-\frac {8 a^{2}+20 a b +15 b^{2}}{8 b^{3} \left (\tanh \left (\frac {x}{2}\right )-1\right )}+\frac {1}{5 b \left (\tanh \left (\frac {x}{2}\right )+1\right )^{5}}-\frac {1}{2 b \left (\tanh \left (\frac {x}{2}\right )+1\right )^{4}}-\frac {4 a +3 b}{12 b^{2} \left (\tanh \left (\frac {x}{2}\right )+1\right )^{3}}-\frac {-7 b -4 a}{8 b^{2} \left (\tanh \left (\frac {x}{2}\right )+1\right )^{2}}-\frac {-8 a^{2}-20 a b -15 b^{2}}{8 b^{3} \left (\tanh \left (\frac {x}{2}\right )+1\right )}-\frac {\left (a^{3}+3 a^{2} b +3 a \,b^{2}+b^{3}\right ) \arctan \left (\frac {2 \left (a +b \right ) \left (\tanh ^{2}\left (\frac {x}{2}\right )\right )-2 a +2 b}{4 \sqrt {a b}}\right )}{b^{3} \sqrt {a b}}\) | \(245\) |
risch | \(\frac {{\mathrm e}^{5 x}}{160 b}-\frac {3 \,{\mathrm e}^{3 x}}{32 b}-\frac {{\mathrm e}^{3 x} a}{24 b^{2}}+\frac {{\mathrm e}^{x} a^{2}}{2 b^{3}}+\frac {11 a \,{\mathrm e}^{x}}{8 b^{2}}+\frac {19 \,{\mathrm e}^{x}}{16 b}+\frac {{\mathrm e}^{-x} a^{2}}{2 b^{3}}+\frac {11 \,{\mathrm e}^{-x} a}{8 b^{2}}+\frac {19 \,{\mathrm e}^{-x}}{16 b}-\frac {3 \,{\mathrm e}^{-3 x}}{32 b}-\frac {{\mathrm e}^{-3 x} a}{24 b^{2}}+\frac {{\mathrm e}^{-5 x}}{160 b}-\frac {\ln \left ({\mathrm e}^{2 x}+\frac {2 a \,{\mathrm e}^{x}}{\sqrt {-a b}}+1\right ) a^{3}}{2 \sqrt {-a b}\, b^{3}}-\frac {3 \ln \left ({\mathrm e}^{2 x}+\frac {2 a \,{\mathrm e}^{x}}{\sqrt {-a b}}+1\right ) a^{2}}{2 \sqrt {-a b}\, b^{2}}-\frac {3 \ln \left ({\mathrm e}^{2 x}+\frac {2 a \,{\mathrm e}^{x}}{\sqrt {-a b}}+1\right ) a}{2 \sqrt {-a b}\, b}-\frac {\ln \left ({\mathrm e}^{2 x}+\frac {2 a \,{\mathrm e}^{x}}{\sqrt {-a b}}+1\right )}{2 \sqrt {-a b}}+\frac {\ln \left ({\mathrm e}^{2 x}-\frac {2 a \,{\mathrm e}^{x}}{\sqrt {-a b}}+1\right ) a^{3}}{2 \sqrt {-a b}\, b^{3}}+\frac {3 \ln \left ({\mathrm e}^{2 x}-\frac {2 a \,{\mathrm e}^{x}}{\sqrt {-a b}}+1\right ) a^{2}}{2 \sqrt {-a b}\, b^{2}}+\frac {3 \ln \left ({\mathrm e}^{2 x}-\frac {2 a \,{\mathrm e}^{x}}{\sqrt {-a b}}+1\right ) a}{2 \sqrt {-a b}\, b}+\frac {\ln \left ({\mathrm e}^{2 x}-\frac {2 a \,{\mathrm e}^{x}}{\sqrt {-a b}}+1\right )}{2 \sqrt {-a b}}\) | \(354\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [B] Leaf count of result is larger than twice the leaf count of optimal. 1199 vs.
\(2 (66) = 132\).
time = 0.42, size = 2346, normalized size = 30.08 \begin {gather*} \text {Too large to display} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F(-1)] Timed out
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Timed out} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F(-2)]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Exception raised: TypeError} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 1.55, size = 805, normalized size = 10.32 \begin {gather*} \frac {{\mathrm {e}}^{-5\,x}}{160\,b}+\frac {{\mathrm {e}}^{5\,x}}{160\,b}+\frac {{\mathrm {e}}^{-x}\,\left (8\,a^2+22\,a\,b+19\,b^2\right )}{16\,b^3}-\frac {\left (2\,\mathrm {atan}\left (\frac {{\mathrm {e}}^x\,{\left (a+b\right )}^3\,\sqrt {a\,b^7}}{2\,a\,b^3\,\sqrt {{\left (a+b\right )}^6}}\right )-2\,\mathrm {atan}\left (\frac {2\,{\mathrm {e}}^{3\,x}\,\left (a^7\,\sqrt {a\,b^7}+b^7\,\sqrt {a\,b^7}+7\,a\,b^6\,\sqrt {a\,b^7}+7\,a^6\,b\,\sqrt {a\,b^7}+21\,a^2\,b^5\,\sqrt {a\,b^7}+35\,a^3\,b^4\,\sqrt {a\,b^7}+35\,a^4\,b^3\,\sqrt {a\,b^7}+21\,a^5\,b^2\,\sqrt {a\,b^7}\right )}{a\,b^3\,\sqrt {{\left (a+b\right )}^6}\,\left (4\,a^4+16\,a^3\,b+24\,a^2\,b^2+16\,a\,b^3+4\,b^4\right )}+\frac {a\,b^8\,{\mathrm {e}}^x\,\sqrt {a\,b^7}\,\left (\frac {4\,\left (2\,a\,b^7\,\sqrt {a^6+6\,a^5\,b+15\,a^4\,b^2+20\,a^3\,b^3+15\,a^2\,b^4+6\,a\,b^5+b^6}+8\,a^2\,b^6\,\sqrt {a^6+6\,a^5\,b+15\,a^4\,b^2+20\,a^3\,b^3+15\,a^2\,b^4+6\,a\,b^5+b^6}+12\,a^3\,b^5\,\sqrt {a^6+6\,a^5\,b+15\,a^4\,b^2+20\,a^3\,b^3+15\,a^2\,b^4+6\,a\,b^5+b^6}+8\,a^4\,b^4\,\sqrt {a^6+6\,a^5\,b+15\,a^4\,b^2+20\,a^3\,b^3+15\,a^2\,b^4+6\,a\,b^5+b^6}+2\,a^5\,b^3\,\sqrt {a^6+6\,a^5\,b+15\,a^4\,b^2+20\,a^3\,b^3+15\,a^2\,b^4+6\,a\,b^5+b^6}\right )}{a^2\,b^{15}\,{\left (a+b\right )}^3}+\frac {2\,\left (a^7\,\sqrt {a\,b^7}+b^7\,\sqrt {a\,b^7}+7\,a\,b^6\,\sqrt {a\,b^7}+7\,a^6\,b\,\sqrt {a\,b^7}+21\,a^2\,b^5\,\sqrt {a\,b^7}+35\,a^3\,b^4\,\sqrt {a\,b^7}+35\,a^4\,b^3\,\sqrt {a\,b^7}+21\,a^5\,b^2\,\sqrt {a\,b^7}\right )}{a^2\,b^{11}\,\sqrt {a\,b^7}\,\sqrt {{\left (a+b\right )}^6}}\right )}{4\,a^4+16\,a^3\,b+24\,a^2\,b^2+16\,a\,b^3+4\,b^4}\right )\right )\,\sqrt {a^6+6\,a^5\,b+15\,a^4\,b^2+20\,a^3\,b^3+15\,a^2\,b^4+6\,a\,b^5+b^6}}{2\,\sqrt {a\,b^7}}-\frac {{\mathrm {e}}^{-3\,x}\,\left (4\,a+9\,b\right )}{96\,b^2}-\frac {{\mathrm {e}}^{3\,x}\,\left (4\,a+9\,b\right )}{96\,b^2}+\frac {{\mathrm {e}}^x\,\left (8\,a^2+22\,a\,b+19\,b^2\right )}{16\,b^3} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________